package com.zhuhong.dao;

import java.util.List;
import java.util.Map;

import org.jeecgframework.minidao.annotation.Arguments;
import org.jeecgframework.minidao.annotation.MiniDao;
import org.jeecgframework.minidao.annotation.Sql;

import com.zhuhong.entity.User;
/**
 * 实体定义规则
 * 字段不允许存在基本类型，必须都是包装类型(因为基本类型有默认值)
 * 基本数据类型  包装类 byte Byte boolean Boolean short Short char Character int Integer long Long float Float double  Double 
 * @author Administrator
 */
@MiniDao
public interface UserDao {

	@Arguments("user")
	Integer insert(User user);
	
	@Arguments("id")
	Integer delete(String id);
	
	@Arguments("user")
	Integer update(User user);
	
	@Arguments({"user","page","rows"})
	List<Map> getListByPage(User user, int page,int rows);
	
	@Sql("SELECT count(*) FROM user")
	Integer getCount();
	
	@Arguments("user")
	List<Map> getList(User user);
}